Skip to content

Conversation

@haecker-felix
Copy link
Collaborator

@haecker-felix haecker-felix commented Nov 12, 2025

Description

Moves pixi add and pixi remove logic from pixi_cli to pixi_api, so other apps can make use of it as well.

Also upgrades rattler_conda_types to 0.42.0, since it contains changes which are needed for pixi_api consumers, like deserializable MatchSpec struct.

Adds to WorkspaceContext:

  • add_conda_deps
  • add_pypi_deps
  • remove_conda_deps
  • remove_pypi_deps

Checklist:

  • I have performed a self-review of my own code

@haecker-felix haecker-felix marked this pull request as draft November 12, 2025 13:50
@haecker-felix haecker-felix changed the title feat(pixi_api): Add add_conda_deps / add_pypi_deps feat(pixi_api): Add add_conda_deps / add_pypi_deps / remove_conda_deps / remove_pypi_deps Nov 12, 2025
@haecker-felix haecker-felix force-pushed the pixi_api_deps branch 2 times, most recently from b5ad91e to 816329d Compare November 22, 2025 15:01
@haecker-felix
Copy link
Collaborator Author

Some tests were failing because of a stack overflow.

2025-11-26T07:26:55.0853870Z     ✔ Created /private/var/folders/8s/1jkm89h96qjdtjr7q3bll2vh0000gn/T/.tmpqfRCPR/pixi.toml
2025-11-26T07:26:55.0853980Z     ✔ Added python~=3.12.0
2025-11-26T07:26:55.0854120Z     ✔ Added pipx==1.7.1
2025-11-26T07:26:55.0854200Z     Added these as pypi-dependencies.
2025-11-26T07:26:55.0854380Z     ✔ Added boltons @ git+https://github.com/mahmoud/boltons.git@d463c60
2025-11-26T07:26:55.0854450Z     Added these as pypi-dependencies.
2025-11-26T07:26:55.0854530Z     Added these only for platform(s): osx-64
2025-11-26T07:26:55.0854610Z     ✔ Added pytest[dev]==8.3.2
2025-11-26T07:26:55.0854680Z     Added these as pypi-dependencies.
2025-11-26T07:26:55.0854750Z     Added these only for platform(s): linux-64
2025-11-26T07:26:55.0854760Z 
2025-11-26T07:26:55.0855450Z     thread 'add_tests::add_pypi_functionality' has overflowed its stack
2025-11-26T07:26:55.0855650Z     fatal runtime error: stack overflow, aborting�[0m
2025-11-26T07:26:55.0855650Z 
2025-11-26T07:26:55.0855790Z     (test �[31;1maborted�[0m with signal �[1m6�[0m: SIGABRT)

I don't think it's a problem with recursion, more a problem with the futures simply being too large / too nested because of the additional pixi_api / WorkspaceContext abstraction layer. Moving them to the heap instead of stack using Box::pin fixes it.

https://users.rust-lang.org/t/stack-overflow-in-async-main-function-due-to-excessive-stack-allocation-not-from-recursion/109571

@haecker-felix haecker-felix marked this pull request as ready for review November 26, 2025 08:27
Copy link
Contributor

@Hofer-Julian Hofer-Julian left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

Let's bring this in, after solving the merge conflicts

@Hofer-Julian Hofer-Julian enabled auto-merge (squash) December 1, 2025 15:42
@Hofer-Julian Hofer-Julian merged commit 35053c5 into prefix-dev:main Dec 1, 2025
134 of 146 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants